package com.platform.usercenter.service.impl;

import com.platform.common.core.domain.entity.SysUser;
import com.platform.usercenter.domain.*;
import com.platform.usercenter.domain.vo.SysUserVO;
import com.platform.usercenter.mapper.*;
import com.platform.usercenter.service.*;
import com.platform.usercenter.teamfc.domain.vo.PostIdAndDeptTypeVo;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 用户 业务层处理
 *
 * @author
 */
@Service
public class RemoteUserServiceImpl implements RemoteUserService
{

    @Resource
    RemoteUserMapper remoteUserMapper;



    /**
     * 用户绑定手表
     *
     * @param sysUser
     */
    @Override
    public void bindWatch( SysUser sysUser ) {
        remoteUserMapper.bindWatch(sysUser);
    }

    /**
     * 用户解绑手表
     *
     * @param sysUser
     */
    @Override
    public void unBindWatch( SysUser sysUser ) {
        remoteUserMapper.unBindWatch(sysUser);
    }

    /**
     * 用户绑定眼镜
     *
     * @param sysUser
     */
    @Override
    public void bindVR( SysUser sysUser ) {
        remoteUserMapper.bindVR(sysUser);
    }

    /**
     * 用户解绑眼镜
     *
     * @param sysUser
     */
    @Override
    public void unBindVR( SysUser sysUser ) {
        remoteUserMapper.unBindVR(sysUser);
    }

    /**
     * 领动的代码账户信息查询接口
     *
     * @param sysUserVo
     * @return
     */
    @Override
    public List< SysUser > getUserByDeptType( SysUserVO sysUserVo  ) {
       return remoteUserMapper.getUserByDeptType(sysUserVo);
    }

    @Override
    public List< CalTeam > getAllTeam( CalTeam calTeam ) {
        return remoteUserMapper.getAllTeam(calTeam);
    }

    @Override
    public List< CalTeam > selectCalTeams( List< String > jobType ) {
        return remoteUserMapper.selectCalTeams(jobType);
    }

    /**
     * 根据用户类型和用户岗位获取用户信息
     *
     * @param postIdAndDeptTypeVo
     * @return
     */
    @Override
    public List< SysUser > getUserByPostIdAndDeptType( PostIdAndDeptTypeVo postIdAndDeptTypeVo ) {

        return remoteUserMapper.getUserByPostIdAndDeptType(postIdAndDeptTypeVo);
    }
}
